import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

/// 紫色背景的自定义行
class CustomRowPurple extends StatelessWidget {
  const CustomRowPurple(
      {required this.title, required this.content, super.key, this.color = const Color(0xFF5C6DFF)});

  final String title;
  final String content;

  ///扩展title的颜色
  final Color color;

  @override
  Widget build(BuildContext context) {
    return Container(
      padding: EdgeInsets.only(left: 12.w, right: 12.w, top: 6.w, bottom: 6.w),
      decoration: BoxDecoration(
        color: const Color(0xFFF7F7FB),
        borderRadius: BorderRadius.circular(4.w),
      ),
      child: Row(
        children: [
          Text(
            title,
            style: TextStyle(
              color: color,
              fontSize: 12.sp,
            ),
          ),
          Text(
            content,
            style: TextStyle(
              color: const Color(0xFF5C6DFF),
              fontSize: 12.sp,
            ),
          ),
        ],
      ),
    );
  }
}
